<?php

!defined('IN_APP') && exit('Access Denied');

class smsmessagecontrol extends base {

    function __construct(& $get, & $post) {
        parent::__construct($get, $post);
        $this->load("user");
        $this->load("customer");
        $this->load("message");
    }

    function ondefault() {
        if (isset($this->post['submit'])) {
            $mobilelist = explode("\r\n", $this->post['mobilestr']);
            if ($mobilelist && $this->post['content'])
                $_ENV['message']->addsms($mobilelist, $this->post['content']);
            echo '<script>alert("发送成功");</script>';
        }
        include template('sendmsg');
    }

}

?>